﻿using System;
using TidyBlog.Entity;
using TidyBlog.Data;

namespace TidyBlog.DAL
{
    /// <summary>
    /// 网站设置数据层
    /// </summary>
    public class SetupDAL
    {
        /// <summary>
        /// 读取网站设置
        /// </summary>
        /// <returns>网站设置</returns>
        public static Setup Read()
        {
            return SimpleORM<Setup>.Read(null);
        }

        /// <summary>
        /// 更新网站设置
        /// </summary>
        /// <param name="setup">网站设置</param>
        /// <returns>影响的行数</returns>
        public static int Update(Setup setup)
        {
            return SimpleORM<Setup>.Update(setup);
        }
    }
}